/**
 * OrderYieldRatioMapperExt
 * Copyright © 2015 - 2017
 * All rights reserved.
 * -----------------------------------
 * 2017-12-29  Created
 */
package com.lzy.product.dao;

import com.lzy.product.dtos.OrderYieldRatioDto;
import org.apache.ibatis.annotations.Param;

import javax.annotation.Resource;
import java.util.List;

@Resource
public interface OrderYieldRatioMapperExt extends OrderYieldRatioMapper {
    /**
     * 根据订单编号查询卡券宝收益率信息
     *
     * @param orderId
     * @return
     */
    OrderYieldRatioDto findOrderYieldRatioByOrderId(@Param("orderId") Long orderId);

    /**
     * 查询可进行收益的记录
     *
     * @param date
     * @return
     */
    List<OrderYieldRatioDto> queryAvailList(@Param("date") String date);

    /**
     * 更新返现结束状态
     *
     * @param date
     * @return
     */
    Integer updateBackedStatus(@Param("date") String date);

    /**
     * 更新返现开始状态
     *
     * @param date
     * @return
     */
    Integer updateStartStatus(@Param("date") String date);
}